package _09StrategyFactoryDesign;

/**
 * 策略模式和装饰模式不同的是，Context不需要实现strtesty这个类
 */
public class Main09 {
    public static void main(String[] args) {
        Strategy strategyA = new StrategyA();
        Context context = new Context(strategyA);
        System.out.println(context.ContextCost(200));
        System.out.println("=====================");
        Strategy strategyB = new StrategyB();
        Context context1 = new Context(strategyB);
        System.out.println(context1.ContextCost(200));
    }
}
